<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page contentType="text/html; charset=UTF-8" %>
<%@ taglib uri="/struts-tags" prefix="s" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/sys/person/SysPerson_changeUserOrg.action";  //应用的地址名
String[] selIds = request.getParameterValues("chkSelf[]");
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>人员表编辑</title>
<script type="text/javascript">
<!--
           $(function(){
               //初始化工作，因为远程载入该界面时无法通过在标签中进行设置相应的验证属性等信息，必须要在这里进行初始化

               //加载下拉机构树
               $('#vcOrgId').combotree({
				    url:'<%=path%>/util/util_searchOrgJsonTree.action',  //获取json格式的节点树
				    valueField:'id',
                    textField:'text',
                    //multiple:true,            //设置是否可以多选
                    required:true,              //要求必填
                    missingMessage:'请选择所属机构',
                    width:'130px'   //不设置时将根据树的大小自动扩展
			    });			   
	           //点击添加按钮操作
			   $('#addBtn').click(function(){
                  $('#SysPerson_modifyItem').submit();
	            });
	            
	            //表单验证及提交处理操作
	           $('#SysPerson_modifyItem').form({
			        url:'<%=basePath%>',
			        onSubmit: function(){
			             if($(this).form('validate')){
			                 $.util.showLoading();
			                 $('#operateWindow').window('close');
                            return true;
			             }else{
			                return false;
			             }
			        },			        
			        success:function(data){
			            $.util.removeLoading();
			            returnOptMsg(data);
			        }
				});
	            
				$("input[type='text'][name]").addClass('input_text');
           });
//-->
</script>
  </head>
  
  <body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
    <s:form action="SysPerson_modifyItem" method="post">
			<%
				for (int i = 0; i < selIds.length; i++) {
			%>
			<input type="hidden" name="vcIds" id="vcIds" value="<%=selIds[i].toString()%>">
			<%
				}
			%>
   <table align="center" width="100%" class="tb_add_th">
				<tr>
					<th align="left">
						选择目标机构:
					</th>
					<td>
						<input type="text" id="vcOrgId" name="vcOrgId" label="所属机构"
							style="width: 130px" />
					</td>
				</tr>
	</table>    
   </s:form>
  </body>
</html>

